﻿using HttpServer.MVC.Controllers;
using HttpServer.MVC.Rendering.Spark;
using Spark;

namespace SparkServer.Controllers
{
    public class HomeController : SparkController
    {

        public HomeController(ISparkServiceContainer container)
            : base(container)
        {
            DefaultMethod = "View";
        }

        #region Overrides of RequestController

        /// <summary>
        /// Creates a new object that is a copy of the current instance.
        /// </summary>
        /// <returns>
        /// A new object that is a copy of this instance.
        /// </returns>
        /// <filterpriority>2</filterpriority>
        public override object Clone()
        {
            return new HomeController(Container);
        }

        #endregion

        public string View()
        {
            //return "Ohh, hello!, so you want to look at user with id #" + Id + "??";


            // TODO: Set headers as needed. DTHRASHER 10Dec2009
            //Utilities.SetMimeType(_CurrentContext.OutgoingResponse, Format.Html);

            return Render(new SparkDataDictionary());
        }

    }
}